
const axios = require('axios');

async function fetch (url = '') {
  try {
    const callback = await axios.get(url);
    return callback?.data;
  } catch (error) {
    return error;
  }
}

module.exports = fetch;
